// openmp HelloWorld
// 2020.10.12
// whsu

#include <stdio.h>
#include <stdlib.h>
#include <omp.h>

void Hello(void);

int main(int argc, char* argv[]) {
    /* Get number of thread from command line */

# pragma omp parallel num_threads(10)
    Hello();
    return 0;
}

void Hello(void) {
    int my_rank = omp_get_thread_num();
    int thread_count = omp_get_num_threads();

    printf("Hello from thread %d of %d\n", my_rank, thread_count);
}

